package com.education.myapplication;

import androidx.appcompat.app.AppCompatActivity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.TextView;
import com.yilian.xlmusic.android.XlMusicActivity;
import com.yilian.xlmusic.android.utils.SelectCallBack;
import com.yilian.xlmusic.android.utils.net.AppConstants;
import com.yilian.xlmusic.android.view.bean.ReturnResult;

public class MainActivity extends AppCompatActivity {
    private TextView select_btn;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);

        AppConstants.setSelectListen("0vX78////0pNLA6W+zHjO4yZEDvrvtymVabF3kFTA1STgKoB2UGI8OrzY4nACiua", new SelectCallBack() {
            @Override
            public void return_result(ReturnResult returnResult) {
                select_btn.setText(returnResult.getName());
            }
        });
        select_btn = findViewById(R.id.select_btn);
        select_btn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(MainActivity.this, XlMusicActivity.class);
                startActivity(intent);
            }
        });
    }
}